export const searchForm = {
  name: "PRODUCT",
  tableBtnItems: [
    {
      name: "新建",
      color: "#1f63ff",
      icon: "Plus",
      type: "add",
      code: "PRODUCT:CREATE-EDIT",
      btnType: "primary"
    }
  ],
  formBtnItems: [
    {
      name: "查询",
      color: "#409eff",
      icon: "Search",
      type: "search",
      code: "",
      btnType: "primary"
    },
    {
      name: "重置",
      color: "",
      icon: "RefreshRight",
      type: "reSet",
      code: "",
      btnType: ""
    },
    {
      name: "下载",
      color: "",
      icon: "Download",
      type: "upload",
      code: "PRODUCT:EXPORT",
      btnType: ""
    },
    {
      name: "下载列表",
      color: "",
      icon: "Link",
      type: "uploadList",
      code: "PRODUCT:EXPORT",
      btnType: ""
    }
  ],
  searchItems: [
    {
      type: "input",
      label: "产品编码",
      prop: "productCode",
      placeholder: "请输入产品编码"
    },
    {
      type: "input",
      label: "产品名称",
      prop: "productName",
      placeholder: "请输入产品名称"
    },

    {
      type: "select",
      label: "是否展示",
      prop: "isShow",
      placeholder: "请选择",
      options: [
        { key: 1, value: "是" },
        { key: 2, value: "否" }
      ]
    },
    {
      type: "select",
      label: "运营商",
      prop: "isp",
      placeholder: "请选择运营商",
      options: []
    },
    {
      type: "filterSelect",
      label: "供应商",
      prop: "supplierCode",
      placeholder: "请选择供应商",
      options: []
    },
    // {
    //   type: "filterSelect",
    //   label: "渠道商",
    //   prop: "channelMerchantCode",
    //   placeholder: "请选择渠道商",
    //   options: [ ]
    // },

    {
      type: "input",
      label: "产品标题",
      prop: "productTitle",
      placeholder: "请输入产品标题"
    },
    {
      type: "select",
      label: "是否统计",
      prop: "isStatistics",
      placeholder: "请选择",
      options: [
        { key: 1, value: "是" },
        { key: 2, value: "否" }
      ]
    }
  ],
  labelwidth: "80px",
  btnSize: "small",
  size: "default"
}

export const tableProps = {
  name: "productList",
  propsList: [
    {
      type: "normal",
      prop: "productCode",
      label: "产品编码",
      width: "100px"
    },
    {
      type: "normal",
      prop: "productName",
      label: "产品名称"
    },
    {
      type: "custom",
      prop: "supplierName",
      slotName:'supplier',
      label: "供应商名称",
    },
    {
      type: "image",
      prop: "intro",
      label: "产品banner",
      width: "100px"
    },
    {
      type: "dispose",
      prop: "isp",
      label: "运营商",
      width: "100px"
    },
    {
      type: "status",
      prop: "isShow",
      label: "是否展示",
      width: "100px"
    },
    {
      type: "normal",
      prop: "productTitle",
      label: "产品标题",
      width: "120px"
    },
    {
      type: "normal",
      prop: "productSubTitle",
      label: "产品副标题",
      width: "120px"
    },
    {
      type: "status",
      prop: "isStatistics",
      label: "是否统计",
      width: "100px"
    },
    {
      type: "handle",
      label: "操作",
      width: "190px",
      btnType: " link",
      list: [
        { name: "查看" ,code: ""},
        { name: "编辑", code: "PRODUCT:CREATE-EDIT" },
        { name: "删除", code: "PRODUCT:DELETE" }
      ]
    }
  ],
  tableSize: "default"
}

export const dialogProps = {
  name: "productList",
  propsList: [
    {
      type: "input",
      label: "产品code",
      prop: "productCode",
      placeholder: "请输入产品code"
    },
    {
      type: "input",
      label: "产品名称",
      prop: "productName",
      placeholder: "请输入产品名称"
    },
    {
      type: "select",
      label: "产品名称",
      prop: "productType",
      placeholder: "请选择",
      options: [
        { key: 1, value: "存量包产品" },
        { key: 2, value: "联合会员产品" }
      ]
    },
    {
      type: "upload",
      label: "产品banner",
      prop: "productBannerUri",
      placeholder: "请输入集合编号"
    },
    {
      type: "select",
      label: "运营商",
      prop: "isp",
      placeholder: "请选择商品分类",
      options: [
        { key: "ChinaMobile", value: "中国移动", id: 1 },
        { key: "ChinaUnicom", value: "中国联通", id: 2 },
        { key: "ChinaTelecom", value: "中国电信", id: 3 },
        { key: "ChinaBroadnet", value: "中国广电", id: 4 },
        { key: "Other", value: "其他", id: 5 }
      ]
    },
    {
      type: "select",
      label: "是否展示",
      prop: "isShow",
      placeholder: "请选择商品分类",
      options: [
        { key: 1, value: "是" },
        { key: 2, value: "否" }
      ]
    },
    {
      type: "input",
      label: "产品标题",
      prop: "productTitle",
      placeholder: "请输入集合编号"
    },
    {
      type: "input",
      label: "产品副标题",
      prop: "productSubTitle",
      placeholder: "请输入集合编号"
    },
    {
      type: "select",
      label: "是否统计",
      prop: "isStatistics",
      options: [
        { key: 1, value: "是" },
        { key: 2, value: "否" }
      ]
    },
    {
      type: "dispose",
      label: "供应商",
      prop: "supplierCode",
      options: []
    },
    {
      type: "custom",
      label: "供应商扩展信息",
      slotName:'supplierExtInfo',
      prop: "supplierExtInfo"
    }
  ],
  title: "详情",
  labelwidth: "80px",
  size: ""
}
